package com.example.leetcode.test;

public class MyAutoInteger {


    private int value;

    public MyAutoInteger(int value) {
        this.value = value;
    }


    public final int getAddAdd(int add){
        int oldValue = value;
        value += add;
        return oldValue;
    }


    public int getValue() {
        return value;
    }

    public void add(int add){
        value+= add;
    }
}
